package tree

type TreeNode struct {
	Value int
	Left  *TreeNode
	Right *TreeNode
}

func NewTreeNode(value int, left *TreeNode, right *TreeNode) *TreeNode {
	return &TreeNode{
		Value: value,
		Left:  left,
		Right: right,
	}
}

func NewTreeNodeWithValue(value int) *TreeNode {
	return &TreeNode{
		Value: value,
		Left:  nil,
		Right: nil,
	}
}
